<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <title>OCR & TTS 结果</title>
    <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.0/css/bootstrap.min.css">
    <style>
        body { padding-top: 50px; }
        .container { max-width: 800px; }
        img { max-width: 100%; height: auto; }
        pre { background-color: #f8f9fa; padding: 15px; }
    </style>
</head>
<body>
    <div class="container">
        <h1 class="text-center">OCR & TTS 结果</h1>
        <hr>
        <div class="text-center">
            <h3>上传的图片:</h3>
            <img src="{{ image_url }}" alt="Uploaded Image">
        </div>
        <hr>
        <div>
            <h3>识别的文本:</h3>
            <pre>{{ recognized_text }}</pre>
        </div>
        <hr>
        <div>
            <h3>生成的音频:</h3>
            <audio controls>
                <source src="{{ audio_url }}" type="audio/mpeg">
                您的浏览器不支持音频元素。
            </audio>
        </div>
        <hr>
        <a href="{{ url_for('index') }}" class="btn btn-secondary">返回</a>
    </div>
</body>
</html>
